package com.cxlin.cwanandroid.model.repository

import com.cxlin.base.model.api.BaseRepository
import com.cxlin.base.model.api.Result
import com.cxlin.cwanandroid.model.api.WanRetrofitClient
import com.cxlin.cwanandroid.model.bean.ArticleList

/**
 *
 * @Author: chenxunlin
 * @Date: 2024/4/30 10:19
 */
class SquareRepository : BaseRepository() {

    suspend fun getSquareArticleList(page:Int):Result<ArticleList>{
        return safeApiCall(
            call = {executeResponse(WanRetrofitClient.service.getSquareArticleList(page))},
            errorMessage = "网络异常"
        )
    }

}